import java.io.BufferedReader;
import java.io.IOException;
import java.io.PrintWriter;


public class OutThread extends Thread {
   
   private String outLine;
   private BufferedReader stdIn;
   private String name;
   private PrintWriter out;
   
   public OutThread(BufferedReader stdIn, PrintWriter out, String name) {
      this.stdIn = stdIn;
      this.name = name;
      this.out = out;
   }

   @Override
   public void run() {
      try {
         while((outLine = stdIn.readLine()) != null) {
            out.println(outLine);
         }
      } catch (IOException e) {
         e.printStackTrace();
      }
   }
}
